package com.yykj.hospital.client.dto;

import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.yykj.common.util.serializer.LocalDate2LongSerializer;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.annotations.CreationTimestamp;
import org.hibernate.annotations.UpdateTimestamp;

import java.time.LocalDateTime;

@Data
public class DoctorArticleDTO {

    private Integer id;

    @ApiModelProperty("标题")
    private String title;

    @ApiModelProperty("副标题")
    private String subTitle;

    @ApiModelProperty("医院ID")
    private Integer hospitalId;

    @ApiModelProperty("医生ID")
    private String doctorId;

    @ApiModelProperty("医生名称")
    private String doctorName;

    @ApiModelProperty("职称")
    private String officer;

    @ApiModelProperty("科室ID")
    private Integer depId;

    @ApiModelProperty("科室名称")
    private String depName;

    @ApiModelProperty("封面")
    private String headImg;

    @ApiModelProperty("阅读数")
    private Integer readCnt;

    @ApiModelProperty("点赞数")
    private Integer praiseCnt;

    @ApiModelProperty("分享数")
    private Integer shareCnt;

    @ApiModelProperty("状态")
    private Boolean status = Boolean.TRUE;

    @ApiModelProperty("创建时间")
    @CreationTimestamp
    @JsonSerialize(using = LocalDate2LongSerializer.class)
    private LocalDateTime addTime;

    @ApiModelProperty("修改时间")
    @UpdateTimestamp
    @JsonSerialize(using = LocalDate2LongSerializer.class)
    private LocalDateTime modifyTime;
}
